﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Bencoder.Types
{
    /// <summary>
    /// Class for representing an integer bencode type
    /// </summary>
    public sealed class BInteger : BElement, IComparable<BInteger>
    {
        private long _Digit;
        
        internal BInteger(long digit)
            :
            base()
        {
            _Digit = digit;
        }

        internal BInteger()
            :
            this(0)
        {

        }

        public static implicit operator long(BInteger bint)
        {
            return bint._Digit;
        }

        public static implicit operator BInteger(long iint)
        {
            return new BInteger(iint);
        }

        public int CompareTo(BInteger other)
        {
            throw new NotImplementedException();
        }
    }
}
